
const seq = require('../connection/mysql_connect'),
    { STRING, INT, TEXT } = require('../../config/db_type_config');
const Essay = seq.define('essay', {
    title: {
        comment: 'essay title',
        type: STRING,
        allowNull: false
    },
    content: {
        comment: 'essay content',
        type: TEXT,
        allowNull: false
    },
    typeid: {
        comment: 'essay type',
        type: INT,
        allowNull: false,

    },
    intro: {
        comment: 'essay intro',
        type: STRING,
        allowNull: false,
    },
    status: {
        comment: 'essay status',
        type: INT,
        defaultValue: 1,
        allowNull: false
    }

})
module.exports = Essay